package io.renren.modules.demo.algorithm;

public class Gene  //一条染色体上的每个基因
{
    private int serialNumber;

    private boolean isWarehouse;  //如果染色体这个位置存的是warehouse就为true，为car就为false

    public int getSerialNumber()
    {
        return serialNumber;
    }

    public void setSerialNumber(int serialNumber)
    {
        this.serialNumber = serialNumber;
    }

    public boolean isWarehouse()
    {
        return isWarehouse;
    }

    public void setWarehouse(boolean warehouse)
    {
        isWarehouse = warehouse;
    }

    public Gene()
    {

    }

    public Gene(boolean isWarehouse, int serialNumber)
    {
        this.isWarehouse = isWarehouse;
        this.serialNumber = serialNumber;
    }
}
